package com.imooc.ecommerce.feign;

import com.imooc.ecommerce.account.BalanceInfo;
import com.imooc.ecommerce.vo.CommonResponse;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;

/**
 * <p>用户账户服务 Feign 接口
 *
 * @author Yaxi.Zhang
 * @since 2022/11/16 19:26
 */
@FeignClient(contextId = "NotSecuredBalanceClient", value = "e-commerce-account-service")
public interface NotSecuredBalanceClient {
    @RequestMapping(value = "/ecommerce-account-service/balance/deduct-balance", method = RequestMethod.PUT)
    CommonResponse<BalanceInfo> deductBalance(@RequestBody BalanceInfo balanceInfo);
}
